package com.map_project;

import java.util.ArrayList;
import android.app.ListActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.ListView;

public class Yfirlit extends ListActivity{

	@Override
    public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		Intent intent = getIntent();
		ArrayList<String> matc = intent.getStringArrayListExtra("match");
		
		getIntent().getSerializableExtra("match");
	    
		setListAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, matc));
		 
		ListView listView = getListView();
		listView.setTextFilterEnabled(true);
    }
	
    @Override 
    public void onListItemClick(ListView l, View v, int position, long id) {
    	Intent intent = new Intent();
    	intent.putExtra("stadur", (int) id);
    	setResult(RESULT_OK, intent);
    	finish();
    }
}